/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package View;

import java.awt.event.ActionListener;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;

/**
 *
 * @author Morten
 */
public class UserViewPanel extends javax.swing.JPanel {

    /**
     * Creates new form UserViewPanel
     */
    public UserViewPanel() {
        initComponents();
    }
    
    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    
    //Makes it possible for the controller to click the button
    public void addButtonUserAccountListener(ActionListener buttonListener) {
        buttonUserAccount.addActionListener(buttonListener);
    }
    
    //Makes it possible for the controller to click the button
    public void addButtonUserTransactionsListener(ActionListener buttonListener) {
        buttonUserTransactions.addActionListener(buttonListener);
    }
    
    //Makes it possible for the controller to click the button
    public void addButtonPricesListener(ActionListener buttonListener) {
        buttonPrices.addActionListener(buttonListener);
    }
    
    //Makes it possible for the controller to click the button
    public void addButtonInsertMoneyListener(ActionListener buttonListener) {
        buttonInsertMoney.addActionListener(buttonListener);
    }
       
    //Makes it possible for the controller to click the button
    public void addButtonLogOffListener(ActionListener buttonListener) {
        buttonLogUserOff.addActionListener(buttonListener);
    }
    
    
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        buttonUserAccount = new javax.swing.JButton();
        buttonUserTransactions = new javax.swing.JButton();
        buttonPrices = new javax.swing.JButton();
        buttonLogUserOff = new javax.swing.JButton();
        buttonInsertMoney = new javax.swing.JButton();

        setBackground(new java.awt.Color(51, 51, 51));

        buttonUserAccount.setFont(new java.awt.Font("Dialog", 0, 12)); // NOI18N
        buttonUserAccount.setText("Edit account");
        buttonUserAccount.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));

        buttonUserTransactions.setFont(new java.awt.Font("Dialog", 0, 12)); // NOI18N
        buttonUserTransactions.setText("Transactions");
        buttonUserTransactions.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));

        buttonPrices.setFont(new java.awt.Font("Dialog", 0, 12)); // NOI18N
        buttonPrices.setText("See Prices");
        buttonPrices.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));

        buttonLogUserOff.setFont(new java.awt.Font("Dialog", 0, 12)); // NOI18N
        buttonLogUserOff.setText("Log off");
        buttonLogUserOff.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));

        buttonInsertMoney.setFont(new java.awt.Font("Dialog", 0, 12)); // NOI18N
        buttonInsertMoney.setText("Insert Money");
        buttonInsertMoney.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(buttonUserAccount, javax.swing.GroupLayout.PREFERRED_SIZE, 85, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap(360, Short.MAX_VALUE))
                    .addGroup(layout.createSequentialGroup()
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(buttonPrices, javax.swing.GroupLayout.PREFERRED_SIZE, 75, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(buttonInsertMoney, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(buttonUserTransactions, javax.swing.GroupLayout.DEFAULT_SIZE, 85, Short.MAX_VALUE))
                        .addGap(0, 0, Short.MAX_VALUE))))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(buttonLogUserOff, javax.swing.GroupLayout.PREFERRED_SIZE, 54, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(buttonLogUserOff)
                .addGap(22, 22, 22)
                .addComponent(buttonUserAccount)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(buttonPrices)
                .addGap(18, 18, 18)
                .addComponent(buttonInsertMoney)
                .addGap(18, 18, 18)
                .addComponent(buttonUserTransactions)
                .addContainerGap(112, Short.MAX_VALUE))
        );
    }// </editor-fold>//GEN-END:initComponents
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton buttonInsertMoney;
    private javax.swing.JButton buttonLogUserOff;
    private javax.swing.JButton buttonPrices;
    private javax.swing.JButton buttonUserAccount;
    private javax.swing.JButton buttonUserTransactions;
    // End of variables declaration//GEN-END:variables

}